
list_1 = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
list_2 = []
list_3 = []
def list_1_while():
    count = 0
    while count < len(list_1):
        num = list_1[count]
        if num % 2 == 0:
            list_2.append(num)
        count += 1
    print(list_2)

def list_1_for():
    for x in list_1:
        if x % 2 == 0:
            list_3.append(x)
    print(list_2)

list_1_while()
print("---------------------------")
list_1_for()